﻿using System;
using System.Diagnostics;
using System.IO;
using System.Xml;
using System.Xml.XPath;
using System.Linq;

namespace PerformanceCounters
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] data = { 1, 2, 5, 8, 11 };

            var result = from d in data
                         where d % 2 == 0
                         select d;
            foreach (int i in result)
            {
                Console.WriteLine(i);
            }
            Console.ReadKey();
            
            var result2 = data.Where(d => d % 2 == 0);

            foreach (int i in result)
            {
                Console.WriteLine(i);
            }            

            Console.ReadKey();
        }
    }
}